<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.11"/>
<title>eRPC API Reference: erpc::Thread Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
  $(window).load(resizeHeight);
</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { init_search(); });
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="customdoxygen.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="nxp_logo_small.png"/></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">eRPC API Reference
   &#160;<span id="projectnumber">Rev. 1.7.4</span>
   </div>
   <div id="projectbrief">NXP Semiconductors</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.11 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="modules.html"><span>API&#160;Reference</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>Class&#160;List</span></a></li>
      <li><a href="classes.html"><span>Class&#160;Index</span></a></li>
      <li><a href="inherits.html"><span>Class&#160;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&#160;Members</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('classerpc_1_1_thread.html','');});
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#pub-types">Public Types</a> &#124;
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#pub-static-methods">Static Public Member Functions</a> &#124;
<a href="#pro-methods">Protected Member Functions</a> &#124;
<a href="classerpc_1_1_thread-members.html">List of all members</a>  </div>
  <div class="headertitle">
<div class="title">erpc::Thread Class Reference<div class="ingroups"><a class="el" href="group__port.html">Porting</a> &raquo; <a class="el" href="group__port__threads.html">Threads</a></div></div>  </div>
</div><!--header-->
<div class="contents">

<p>Simple thread class.  
 <a href="classerpc_1_1_thread.html#details">More...</a></p>

<p><code>#include &lt;<a class="el" href="erpc__threading_8h_source.html">erpc_threading.h</a>&gt;</code></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-types"></a>
Public Types</h2></td></tr>
<tr class="memitem:a51c5d04c6a574d77d38db8d59c77a9d9"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a51c5d04c6a574d77d38db8d59c77a9d9"></a>
typedef void *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_thread.html#a51c5d04c6a574d77d38db8d59c77a9d9">thread_id_t</a></td></tr>
<tr class="memdesc:a51c5d04c6a574d77d38db8d59c77a9d9"><td class="mdescLeft">&#160;</td><td class="mdescRight">Unique identifier for a thread. <br /></td></tr>
<tr class="separator:a51c5d04c6a574d77d38db8d59c77a9d9"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:a5bdd8acf426795e33c858e070ba0e8bb"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_thread.html#a5bdd8acf426795e33c858e070ba0e8bb">Thread</a> (const char *name=0)</td></tr>
<tr class="memdesc:a5bdd8acf426795e33c858e070ba0e8bb"><td class="mdescLeft">&#160;</td><td class="mdescRight">Default constructor for use with the <a class="el" href="classerpc_1_1_thread.html#accdb82347a2d77477500b5dc8a9e1902" title="This function initializes thread. ">init()</a> method.  <a href="#a5bdd8acf426795e33c858e070ba0e8bb">More...</a><br /></td></tr>
<tr class="separator:a5bdd8acf426795e33c858e070ba0e8bb"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa1eb90e1cae20fc83ab9a631f7c705e3"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_thread.html#aa1eb90e1cae20fc83ab9a631f7c705e3">Thread</a> (<a class="el" href="group__port__threads.html#ga2c28da51e513ff5423a1c6d6aa56fef9">thread_entry_t</a> entry, uint32_t priority=0, uint32_t stackSize=0, const char *name=0)</td></tr>
<tr class="memdesc:aa1eb90e1cae20fc83ab9a631f7c705e3"><td class="mdescLeft">&#160;</td><td class="mdescRight">Constructor.  <a href="#aa1eb90e1cae20fc83ab9a631f7c705e3">More...</a><br /></td></tr>
<tr class="separator:aa1eb90e1cae20fc83ab9a631f7c705e3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af1e25588ebe47a2a6d79ef8c686a992b"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="af1e25588ebe47a2a6d79ef8c686a992b"></a>
virtual&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_thread.html#af1e25588ebe47a2a6d79ef8c686a992b">~Thread</a> (void)</td></tr>
<tr class="memdesc:af1e25588ebe47a2a6d79ef8c686a992b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Destructor. <br /></td></tr>
<tr class="separator:af1e25588ebe47a2a6d79ef8c686a992b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa4513a84070e0246a0ed1a804cfe85b4"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_thread.html#aa4513a84070e0246a0ed1a804cfe85b4">setName</a> (const char *name)</td></tr>
<tr class="memdesc:aa4513a84070e0246a0ed1a804cfe85b4"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function sets name for thread.  <a href="#aa4513a84070e0246a0ed1a804cfe85b4">More...</a><br /></td></tr>
<tr class="separator:aa4513a84070e0246a0ed1a804cfe85b4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a0a7bea50b487914f2f2383d731b4306e"><td class="memItemLeft" align="right" valign="top">const char *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_thread.html#a0a7bea50b487914f2f2383d731b4306e">getName</a> (void) const </td></tr>
<tr class="memdesc:a0a7bea50b487914f2f2383d731b4306e"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function returns name of thread.  <a href="#a0a7bea50b487914f2f2383d731b4306e">More...</a><br /></td></tr>
<tr class="separator:a0a7bea50b487914f2f2383d731b4306e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:accdb82347a2d77477500b5dc8a9e1902"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_thread.html#accdb82347a2d77477500b5dc8a9e1902">init</a> (<a class="el" href="group__port__threads.html#ga2c28da51e513ff5423a1c6d6aa56fef9">thread_entry_t</a> entry, uint32_t priority=0, uint32_t stackSize=0)</td></tr>
<tr class="memdesc:accdb82347a2d77477500b5dc8a9e1902"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function initializes thread.  <a href="#accdb82347a2d77477500b5dc8a9e1902">More...</a><br /></td></tr>
<tr class="separator:accdb82347a2d77477500b5dc8a9e1902"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aae9e0fa0c6b9f2a0bd9e2a6fbc43dc56"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_thread.html#aae9e0fa0c6b9f2a0bd9e2a6fbc43dc56">start</a> (void *arg=0)</td></tr>
<tr class="memdesc:aae9e0fa0c6b9f2a0bd9e2a6fbc43dc56"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function starts thread execution.  <a href="#aae9e0fa0c6b9f2a0bd9e2a6fbc43dc56">More...</a><br /></td></tr>
<tr class="separator:aae9e0fa0c6b9f2a0bd9e2a6fbc43dc56"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a220ea24e7e421b0a84736c0818fbe59b"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classerpc_1_1_thread.html#a51c5d04c6a574d77d38db8d59c77a9d9">thread_id_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_thread.html#a220ea24e7e421b0a84736c0818fbe59b">getThreadId</a> (void) const </td></tr>
<tr class="memdesc:a220ea24e7e421b0a84736c0818fbe59b"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function returns current thread id.  <a href="#a220ea24e7e421b0a84736c0818fbe59b">More...</a><br /></td></tr>
<tr class="separator:a220ea24e7e421b0a84736c0818fbe59b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a46180774600273a9a0445e28aafd4af7"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_thread.html#a46180774600273a9a0445e28aafd4af7">operator==</a> (<a class="el" href="classerpc_1_1_thread.html">Thread</a> &amp;o)</td></tr>
<tr class="memdesc:a46180774600273a9a0445e28aafd4af7"><td class="mdescLeft">&#160;</td><td class="mdescRight">Compare operator compares two threads.  <a href="#a46180774600273a9a0445e28aafd4af7">More...</a><br /></td></tr>
<tr class="separator:a46180774600273a9a0445e28aafd4af7"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-static-methods"></a>
Static Public Member Functions</h2></td></tr>
<tr class="memitem:a22708d7df4c6ddd86564abbc7f81af08"><td class="memItemLeft" align="right" valign="top">static void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_thread.html#a22708d7df4c6ddd86564abbc7f81af08">sleep</a> (uint32_t usecs)</td></tr>
<tr class="memdesc:a22708d7df4c6ddd86564abbc7f81af08"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function puts thread to sleep.  <a href="#a22708d7df4c6ddd86564abbc7f81af08">More...</a><br /></td></tr>
<tr class="separator:a22708d7df4c6ddd86564abbc7f81af08"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a0dffdcfac14c0689620172a624ad4bbb"><td class="memItemLeft" align="right" valign="top">static <a class="el" href="classerpc_1_1_thread.html#a51c5d04c6a574d77d38db8d59c77a9d9">thread_id_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_thread.html#a0dffdcfac14c0689620172a624ad4bbb">getCurrentThreadId</a> (void)</td></tr>
<tr class="memdesc:a0dffdcfac14c0689620172a624ad4bbb"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function returns thread id where function is called.  <a href="#a0dffdcfac14c0689620172a624ad4bbb">More...</a><br /></td></tr>
<tr class="separator:a0dffdcfac14c0689620172a624ad4bbb"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af2628d839ac1a6000f82cc03124df7cb"><td class="memItemLeft" align="right" valign="top">static <a class="el" href="classerpc_1_1_thread.html">Thread</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_thread.html#af2628d839ac1a6000f82cc03124df7cb">getCurrentThread</a> (void)</td></tr>
<tr class="memdesc:af2628d839ac1a6000f82cc03124df7cb"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function returns <a class="el" href="classerpc_1_1_thread.html" title="Simple thread class. ">Thread</a> instance where functions is called.  <a href="#af2628d839ac1a6000f82cc03124df7cb">More...</a><br /></td></tr>
<tr class="separator:af2628d839ac1a6000f82cc03124df7cb"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pro-methods"></a>
Protected Member Functions</h2></td></tr>
<tr class="memitem:a549c658e575af0342283a688e58b26eb"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a549c658e575af0342283a688e58b26eb"></a>
virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classerpc_1_1_thread.html#a549c658e575af0342283a688e58b26eb">threadEntryPoint</a> (void)</td></tr>
<tr class="memdesc:a549c658e575af0342283a688e58b26eb"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function execute entry function. <br /></td></tr>
<tr class="separator:a549c658e575af0342283a688e58b26eb"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Simple thread class. </p>
</div><h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a class="anchor" id="a5bdd8acf426795e33c858e070ba0e8bb"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">Thread::Thread </td>
          <td>(</td>
          <td class="paramtype">const char *&#160;</td>
          <td class="paramname"><em>name</em> = <code>0</code></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Default constructor for use with the <a class="el" href="classerpc_1_1_thread.html#accdb82347a2d77477500b5dc8a9e1902" title="This function initializes thread. ">init()</a> method. </p>
<p>If this constructor is used, the <a class="el" href="classerpc_1_1_thread.html#accdb82347a2d77477500b5dc8a9e1902" title="This function initializes thread. ">init()</a> method must be called before the thread can be started.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">name</td><td>Optional name for the thread. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="aa1eb90e1cae20fc83ab9a631f7c705e3"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">Thread::Thread </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__port__threads.html#ga2c28da51e513ff5423a1c6d6aa56fef9">thread_entry_t</a>&#160;</td>
          <td class="paramname"><em>entry</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>priority</em> = <code>0</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>stackSize</em> = <code>0</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char *&#160;</td>
          <td class="paramname"><em>name</em> = <code>0</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Constructor. </p>
<p>This constructor fully initializes the thread object.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">entry</td><td></td></tr>
    <tr><td class="paramname">priority</td><td></td></tr>
    <tr><td class="paramname">stackSize</td><td></td></tr>
    <tr><td class="paramname">name</td><td>Optional name for the thread. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a class="anchor" id="aa4513a84070e0246a0ed1a804cfe85b4"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void erpc::Thread::setName </td>
          <td>(</td>
          <td class="paramtype">const char *&#160;</td>
          <td class="paramname"><em>name</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>This function sets name for thread. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">name</td><td>Name for thread. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a0a7bea50b487914f2f2383d731b4306e"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">const char* erpc::Thread::getName </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>This function returns name of thread. </p>
<dl class="section return"><dt>Returns</dt><dd>Name of thread. </dd></dl>

</div>
</div>
<a class="anchor" id="accdb82347a2d77477500b5dc8a9e1902"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void Thread::init </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__port__threads.html#ga2c28da51e513ff5423a1c6d6aa56fef9">thread_entry_t</a>&#160;</td>
          <td class="paramname"><em>entry</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>priority</em> = <code>0</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>stackSize</em> = <code>0</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This function initializes thread. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">entry</td><td>Entry function. </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">priority</td><td>Task priority. </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">stackSize</td><td>Stack size. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="aae9e0fa0c6b9f2a0bd9e2a6fbc43dc56"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void Thread::start </td>
          <td>(</td>
          <td class="paramtype">void *&#160;</td>
          <td class="paramname"><em>arg</em> = <code>0</code></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This function starts thread execution. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">arg</td><td>Function argument. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a22708d7df4c6ddd86564abbc7f81af08"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void Thread::sleep </td>
          <td>(</td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>usecs</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>This function puts thread to sleep. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">usecs</td><td>Time for sleeping. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a220ea24e7e421b0a84736c0818fbe59b"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classerpc_1_1_thread.html#a51c5d04c6a574d77d38db8d59c77a9d9">thread_id_t</a> erpc::Thread::getThreadId </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>This function returns current thread id. </p>
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="classerpc_1_1_thread.html" title="Simple thread class. ">Thread</a> id. </dd></dl>

</div>
</div>
<a class="anchor" id="a0dffdcfac14c0689620172a624ad4bbb"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static <a class="el" href="classerpc_1_1_thread.html#a51c5d04c6a574d77d38db8d59c77a9d9">thread_id_t</a> erpc::Thread::getCurrentThreadId </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>This function returns thread id where function is called. </p>
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="classerpc_1_1_thread.html" title="Simple thread class. ">Thread</a> id. </dd></dl>

</div>
</div>
<a class="anchor" id="af2628d839ac1a6000f82cc03124df7cb"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classerpc_1_1_thread.html">Thread</a> * Thread::getCurrentThread </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>This function returns <a class="el" href="classerpc_1_1_thread.html" title="Simple thread class. ">Thread</a> instance where functions is called. </p>
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="classerpc_1_1_thread.html" title="Simple thread class. ">Thread</a> instance. </dd></dl>

</div>
</div>
<a class="anchor" id="a46180774600273a9a0445e28aafd4af7"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool Thread::operator== </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="classerpc_1_1_thread.html">Thread</a> &amp;&#160;</td>
          <td class="paramname"><em>o</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Compare operator compares two threads. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">o</td><td><a class="el" href="classerpc_1_1_thread.html" title="Simple thread class. ">Thread</a> instance.</td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">true</td><td>When threads are same. </td></tr>
    <tr><td class="paramname">false</td><td>When threads aren't same. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<hr/>The documentation for this class was generated from the following files:<ul>
<li><a class="el" href="erpc__threading_8h_source.html">erpc_threading.h</a></li>
<li>erpc_threading_pthreads.cpp</li>
</ul>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- HTML footer for doxygen 1.8.5-->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul class="foot">
    <li class="footer">Copyright 2016-2020 NXP Semiconductors. All rights reserved.
    </li>
  </ul>
</div>
</body>
</html>
